//********************************************************************
//  Dot.java       Author: Lewis/Loftus (Circle.java)
//  			   Modified by:  Jason M. Campbell
//
//  Represents a dot on a die for the Die class.
//********************************************************************

import java.awt.*;

public class Dot
{
   private int diameter, x, y;
   private Color color;

   //-----------------------------------------------------------------
   //  Constructor: Sets up the dot with the specified values.
   //-----------------------------------------------------------------
   public Dot (int size, Color shade, int upperX, int upperY)
   {
      diameter = size;
      color = shade;
      x = upperX;
      y = upperY;
   } // end Dot constructor

   //-----------------------------------------------------------------
   //  Draws this dot in the specified graphics context.
   //-----------------------------------------------------------------
   public void drawDot (Graphics g)
   {
      g.setColor (color);
      g.fillOval (x, y, diameter, diameter);
   } // end drawDot

   //-----------------------------------------------------------------
   //  Diameter mutator.
   //-----------------------------------------------------------------
   public void setDiameter (int size)
   {
      diameter = size;
   } // end setDiameter

   //-----------------------------------------------------------------
   //  Color mutator.
   //-----------------------------------------------------------------
   public void setColor (Color shade)
   {
      color = shade;
   } // end setColor

   //-----------------------------------------------------------------
   //  X mutator.
   //-----------------------------------------------------------------
   public void setX (int upperX)
   {
      x = upperX;
   } // end setX

   //-----------------------------------------------------------------
   //  Y mutator.
   //-----------------------------------------------------------------
   public void setY (int upperY)
   {
      y = upperY;
   } // end setY

   //-----------------------------------------------------------------
   //  Diameter accessor.
   //-----------------------------------------------------------------
   public int getDiameter ()
   {
      return diameter;
   } // end getDiameter

   //-----------------------------------------------------------------
   //  Color accessor.
   //-----------------------------------------------------------------
   public Color getColor ()
   {
      return color;
   } // end getColor

   //-----------------------------------------------------------------
   //  X accessor.
   //-----------------------------------------------------------------
   public int getX ()
   {
      return x;
   } // end getX

   //-----------------------------------------------------------------
   //  Y accessor.
   //-----------------------------------------------------------------
   public int getY ()
   {
      return y;
   } // end getY   
} // end class Dot
